package bdd_handler;

import java.sql.*;

public class bdd {

	private Connection conn=null;
	
	public bdd(){
		try {
			Class.forName("com.mysql.jdbc.Driver");
			System.out.println("Driver O.K.");

			String url = "jdbc:mysql://localhost:3306/Java";
			String user = "root";
			String passwd = "root";

			conn = DriverManager.getConnection(url, user, passwd);
			System.out.println("Connexion effective !");         

		} catch (Exception e) {
			e.printStackTrace();
		}      
	}
	
	public Connection getConnection(){
		return this.conn;
	}
}
